<template>
  <div class="app-container">
    <el-form :model="queryParams" ref="queryForm" :inline="true" label-width="68px">
      <el-form-item>
        <el-button type="cyan" icon="el-icon-search" size="mini" @click="handleQuery">刷新</el-button>
<!--        <el-button icon="el-icon-refresh" size="mini" @click="resetQuery">重置</el-button>-->
      </el-form-item>
    </el-form>
    <div v-for="(item, index) in logContent" :key="index">
      <span>{{item}}</span>
      <el-divider></el-divider>
    </div>

  </div>
</template>

<script>
import { readLatestLog } from "@/api/system/runningLog";

export default {
  name: "RunningLog",
  data() {
    return {
      logContent: [],
      queryParams: {
      }
    };
  },
  created() {
    this.getLogContent();
  },
  methods: {
    /** 查询公告列表 */
    getLogContent() {
      readLatestLog('app').then(response => {
        this.logContent = response.data;
      });
    },
    /** 搜索按钮操作 */
    handleQuery() {
      this.getLogContent();
    },
  }
};
</script>
